package com.example.yk_lx;

import android.app.Application;

import com.alibaba.android.arouter.launcher.ARouter;
import com.hyphenate.chat.EMClient;
import com.hyphenate.chat.EMOptions;
import com.hyphenate.easeui.EaseIM;
import com.uuzuche.lib_zxing.activity.ZXingLibrary;

public class App extends Application {
    @Override
    public void onCreate() {
        super.onCreate();
        ARouter.openLog();
        ARouter.openDebug();
        ARouter.init(this);

        ZXingLibrary.initDisplayOpinion(this);

        EMOptions options = new EMOptions();
        options.setAppKey("1104230426171869#2203im");
        EMClient.getInstance().init(this, options);
        //EaseIM 初始化
        if(EaseIM.getInstance().init(this, options)){
            //在做打包混淆时，关闭 debug 模式，避免消耗不必要的资源
            EMClient.getInstance().setDebugMode(true);
            //EaseIM 初始化成功之后再调用注册消息监听的代码 ...
        }

    }
}
